# Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>

pkgname=alembic
pkgver=1.8.5
pkgrel=2
pkgdesc="An open framework for storing and sharing scene data"
arch=('loong64' 'x86_64')
url="http://www.alembic.io/"
license=('BSD')
depends=('imath' 'hdf5')
makedepends=('cmake' 'ninja')
source=($pkgname-$pkgver.tar.gz::https://github.com/alembic/alembic/archive/${pkgver}.tar.gz)
sha512sums=('89a480970eb09893112bf650011ede852205d1fa3718680a3983392bbcf3eb3f22f4ec01f42d12bfcaf655ce43d7d6f583b764ec03f4c5a84023359502b3636e')

build() {
  cd "${pkgname}-${pkgver}"

  cmake . \
    -Bbuild \
    -GNinja \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DUSE_HDF5=ON

  ninja -C build
}

package() {
  cd "${pkgname}-${pkgver}"

  install -Dm644 LICENSE.txt "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE

  DESTDIR="${pkgdir}/" ninja -C build install
}

# vim:set ts=2 sw=2 et:
